<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        // 题目一
        var a = prompt("请输入战士连续作战多少小时？");
        var b = parseInt( a / 24 );
        var c = a % 24;
        alert("战士连续作战" + b +"天" + c + "小时");
    </script>
</body>
</html>